From: Roland McGrath Date: Mon, 19 Apr 1993 20:36:23 +0000 (+0000) Subject: (find-file-noselect): Never set SAME-TRUENAME to a buffer whose X-Git-Tag: archive/raspbian/1%29.2+1-2+rpi1^2~5^2~96507 X-Git-Url: https://dgit.raspbian.org/%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:///%22http:/www.example.com/cgi/%22https:/www.github.com/%22bookmarks:/?a=commitdiff_plain;h=4269ed64c85cdfb85d20a08fad0fe207ac7bf217;p=emacs.git (find-file-noselect): Never set SAME-TRUENAME to a buffer whose buffer-file-name is nil. --- diff --git a/lisp/files.el b/lisp/files.el index 3423d87f2ce..b9515ddfc7d 100644 --- a/lisp/files.el +++ b/lisp/files.el @@ -468,7 +468,8 @@ The buffer is not selected, just returned to the caller." (while (and (not found) list) (save-excursion (set-buffer (car list)) - (if (string= buffer-file-truename truename) + (if (and buffer-file-name + (string= buffer-file-truename truename)) (setq found (car list)))) (setq list (cdr list))) found)))